package 力扣日常刷题.木22一月.第02天0109;

/**
 * @author 帅小伙
 * @date 2022/1/9
 * @description  https://leetcode-cn.com/problems/concatenation-of-array/
 */
public class Demo04数组简单数组串联 {


    public int[] getConcatenation(int[] nums) {
        int[] res = new int[nums.length*2];
        int n = nums.length;
        for (int i = 0; i < nums.length; i++) {
            res[i] = nums[i];
            res[i+n] = nums[i];
        }
        return res;
    }

}
